﻿using System.Windows;
using SGT.ViewModel;
using System.Windows.Controls;
using SGT.Views;
using Fluent;
using Stema.Controls;
using System.Windows.Media.Imaging;
using System;

namespace SGT
{
    /// <summary>
    /// Interaction logic for MainWindow.xaml
    /// </summary>
    public partial class MainWindow : RibbonWindow
    {
        private Page _ABMProvedores;
       // private Page _ABMDepositos;
        private Page _ABMMercaderias;
        private Page _RemitoEntrada;
        private Page _RemitoGrid;
        private Page _Portada;
   
        
        public MainWindow()
        {
            InitializeComponent();
            DataContext = new MainViewModel();
            Closing += (s, e) => ViewModelLocator.Cleanup();
            //EstablecerPaginaPrincipal();
    
    
            
        }

        public bool NavigatioPaneOff
        {
            get { return navigationPane.Visibility == System.Windows.Visibility.Collapsed; }
            set
            {
                navigationPane.Visibility = value ? System.Windows.Visibility.Collapsed : System.Windows.Visibility.Visible;
            }
        }
        public bool ExpanderPaneOff
        {
            get { return navigationPaneExpander.Visibility == System.Windows.Visibility.Collapsed; }
            set
            {
                navigationPaneExpander.Visibility = value ? System.Windows.Visibility.Collapsed : System.Windows.Visibility.Visible;
            }
        }

        private void navigationPaneExpander_CloseButtonClick(object sender, RoutedEventArgs e)
        {

        }

        private void Button_Click(object sender, RoutedEventArgs e)
        {
            NavigationPaneItem item = new NavigationPaneItem();
            item.Header = "Hola";
            item.Content = "contenido";
            item.Image = new BitmapImage(new Uri(@"pack://application:,,,/SGT;component/Img/folderopen.ico"));

            navigationPane.Items.Add(item);
        }



      /*  private void AdministrarProveedores_Click(object sender, RoutedEventArgs e)
        {
            if (_ABMProvedores == null)
                _ABMProvedores = new ABMProvedoresView();
            this.frame1.Navigate(_ABMProvedores);
        }

        private void RemitoEntradaDeposito_Click(object sender, RoutedEventArgs e)
        {
            /*if (_RemitoEntrada == null)
                _RemitoEntrada = new RemitoEntradaDepositoView();
            this.frame1.Navigate(_RemitoEntrada);*/
        }
 /*       private void AdministrarMercaderias_Click(object sender, RoutedEventArgs e)
        {
            if (_ABMMercaderias == null)
                _ABMMercaderias = new ABMMercaderiasView();
            this.frame1.Navigate(_ABMMercaderias);
        }

        private void EstablecerPaginaPrincipal()
        {
            if (_Portada == null)
                _Portada = new PortadaView();
            this.frame1.Navigate(_Portada);
        }
        private void RemitoGrid_Click(object sender, RoutedEventArgs e)
        {
            if (_RemitoGrid == null)
                _RemitoGrid = new RemitoGridView();
              this.frame1.Navigate(_RemitoGrid);
        }

    }*/
}
